package cn.zazhi.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Component;

import cn.zazhi.dao.CategoryDao;
import cn.zazhi.pojo.Category;
import cn.zazhi.service.CategoryService;

@Component("categoryService")
public class CategoryServiceImpl implements CategoryService{
	private CategoryDao categoryDao;

	public CategoryDao getCategoryDao() {
		return categoryDao;
	}

	@Resource(name="categoryDao")
	public void setCategoryDao(CategoryDao categoryDao) {
		this.categoryDao = categoryDao;
	}

	public void addCategory(Category category) {
		categoryDao.save(category);
		
	}

	public void deleteAllCategory() {
		// TODO Auto-generated method stub
		
	}

	public void deleteCategory(Category category) {
		// TODO Auto-generated method stub
		
	}

	public void updateCategory(Category category) {
		// TODO Auto-generated method stub
		
	}

}
